<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org">
<head>
    <th:block th:include="include :: header('项目详情')"/>
</head>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">

    <form class="form-horizontal m-t" id="jobLogForm" th:if="${name == 'project'}">
        <div class="form-group">
            <label class="col-sm-3 control-label">项目名称：</label>
            <div class="form-control-static" th:text="${project.pname}">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">项目编号：</label>
            <div class="form-control-static" th:text="${project.pid}">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">项目负责人：</label>
            <div class="form-control-static" th:text="${project.pleader}">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">项目金额（￥）：</label>
            <div class="form-control-static" th:text="${project.pvalue}">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">项目周期（周）：</label>
            <div class="form-control-static" th:text="${project.pcycle}">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">订单类别：</label>
            <div class="form-control-static" th:text="${project.type.typeName}">
            </div>
        </div>
        <div class="hr-line-dashed"></div>
        <!-- 客户信息栅格 -->
        <div class="col-sm-12">
            <div class="ibox float-e-margins">
                <div class="ibox-title">
                    <h5>客户信息</h5>
                </div>
                <div class="ibox-content">
                    <div class="table-responsive">
                        <table class="table table-bordered table-striped">
                            <thead>
                            <tr>
                                <th>
                                    客户编号
                                </th>
                                <th>
                                    客户名称
                                </th>
                                <th>
                                    客户类型
                                </th>
                                <th>
                                    联系人
                                </th>
                                <th>
                                    职位
                                </th>
                                <th>
                                    联系方式
                                </th>
                                <th>
                                    备注
                                </th>
                            </tr>
                            </thead>
                            <tbody>
                            <tr>
                                <td th:text="${project.customer.cid}"></td>
                                <td th:text="${project.customer.cname}"></td>
                                <td th:text="${project.customer.ctype}"></td>
                                <td th:text="${project.customer.contactPerson}"></td>
                                <td th:text="${project.customer.contactPersonTitle}"></td>
                                <td th:text="${project.customer.contactNum}"></td>
                                <td th:text="${project.customer.remark}"></td>
                            </tr>
                            </tbody>
                        </table>
                    </div>


                </div>
            </div>
        </div>
        <!-- 订单信息—项目内容 -->
        <div class="col-sm-12">
            <div class="ibox float-e-margins">
                <div class="ibox-title">
                    <h5>订单信息—项目内容</h5>
                </div>
                <div class="ibox-content">
                    <div class="table-responsive">
                        <table class="table table-bordered table-striped">
                            <thead>
                            <tr>
                                <th>
                                    项目内容
                                </th>
                                <th>
                                    项目风格
                                </th>
                                <th>
                                    项目类型
                                </th>
                                <th>
                                    项目创立时间
                                </th>
                                <th>
                                    项目完成时间
                                </th>
                                <th>
                                    备注
                                </th>
                            </tr>
                            </thead>
                            <tbody>
                            <tr>
                                <td th:text="${project.projectContent}"></td>
                                <td th:text="${project.projectStyle}"></td>
                                <td th:text="${project.projectType}"></td>
                                <td th:text="${#dates.format(project.projectStartTime,'yyyy-MM-dd')}"></td>
                                <td th:if="${project.projectEndTime} eq null">项目未完成</td>
                                <td th:if="${project.projectEndTime} ne null" th:text="${#dates.format(project.projectEndTime,'yyyy-MM-dd')}"></td>
                                <td th:text="${project.additionalInfo}"></td>
                            </tr>
                            </tbody>
                        </table>
                    </div>


                </div>
            </div>
        </div>
        <!-- 订单信息—产品清单（零售、工程订单） -->
        <div class="col-sm-12">
            <div class="ibox float-e-margins">
                <div class="ibox-title">
                    <h5>订单信息—产品清单（零售、工程订单）</h5>
                </div>
                <div class="ibox-content">
                    <div class="table-responsive">
                        <table class="table table-bordered table-striped">
                            <thead>
                            <tr>
                                <th>
                                    产品编号
                                </th>
                                <th>
                                    产品名称
                                </th>
                                <th>
                                    数量
                                </th>
                                <th>
                                    单位
                                </th>
                                <th>
                                    单价
                                </th>
                                <th>
                                    总额
                                </th>
                                <th>
                                    备注
                                </th>
                            </tr>
                            </thead>
                            <tbody>
                            <tr>
                                <td th:text="${project.productList.productListId}"></td>
                                <td th:text="${project.productList.productName}"></td>
                                <td th:text="${project.productList.productNum}"></td>
                                <td th:text="${project.productList.unit}"></td>
                                <td th:text="${project.productList.productPrice}"></td>
                                <td th:text="${project.productList.productSum}"></td>
                                <td th:text="${project.productList.remark}"></td>
                            </tr>
                            </tbody>
                        </table>
                    </div>


                </div>
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">附加信息：</label>
            <div class="form-control-static" th:text="${project.order.orderInfo}">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">客户资料查看：</label>
            <div class="form-control-static" th:text="${project.order.customerFile}">
            </div>
        </div>
    </form>

</div>
</body>
</html>